package com.cgs.query.service.jpa

import com.cgs.query.domain.ProjectErrorLog
import com.cgs.query.domain.ProjectLockLog
import com.cgs.query.domain.QueryDefine
import org.springframework.data.domain.Page
import org.springframework.data.domain.PageRequest
import org.springframework.data.domain.Pageable
import org.springframework.data.jpa.repository.JpaRepository


interface ProjectLockLogRepository : JpaRepository<ProjectLockLog, String> {
    fun deleteByProjectName(projectName: String)

    fun findByProjectNameOrderByTimeDesc(name: String): List<ProjectLockLog>?
}

interface ProjectErrorLogRepository : JpaRepository<ProjectErrorLog, String> {
    fun deleteByProjectName(projectName: String)

    fun findByProjectNameOrderByTimeDesc(name: String, pageable: Pageable): Page<ProjectErrorLog>?
}
